﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Management.Automation;

using CrystalDecisions.Enterprise.Desktop;

namespace BO.Management.PowerShell
{
    [Cmdlet(VerbsLifecycle.Submit, "Event", DefaultParameterSetName = CONNECT_SECWINAD)]
    public class SubmitEvent:BaseActionObject<EventProvider, Event>
    {

        public override EventProvider GetProvider()
        {
            return new EventProvider(this.LogonProvider);
        }

        public override void WorkWithSingleObject(Event boeObject)
        {
            boeObject.UserEvent.Trigger();
            BoeProvider.Commit(boeObject);
        }
        
    }
}
